x = 50


def func():
    global x
    print('x的值是', x)
    x = 2
    print('修改全局x的值为', x)


func()
print('x的值是', x)
